﻿using System.Data.Entity.ModelConfiguration;
using TavDom.Library.Entities.Concrete;

namespace TavDom.Library.Entities.Mappings.EntityFramework
{
    public class ContentTypeMap : EntityTypeConfiguration<ContentType>
    {
        public ContentTypeMap()
        {
            HasRequired(e => e.CreatedBy).WithMany(u => u.ContentTypeCreated).Map(m => m.MapKey("CreatedBy"));
            HasRequired(e => e.UpdatedBy).WithMany(u => u.ContentTypeCreated).Map(m => m.MapKey("UpdatedBy"));
        }
    }
}
